import unittest
# 导入参数和插件
from parameterized import parameterized

def add(a, b):
    return a + b
# 定义测试类
class TestAdd08(unittest.TestCase):
    # 测试方法(测试用例)
    # 为测试方法提供参数
    @parameterized.expand([
        (1, 2, 3),
        (3, 4, 8),
        (5, 6, 11)
    ])
    def test_add(self, n1, n2, expect):
        result = add(n1, n2)
        self.assertEqual(result, expect)

if __name__ == '__main__':
    unittest.main()